<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>分支结构</title>
</head>
<body>
  <script>
    var number = Math.floor(Math.random()*50 + 1);
    if(number % 2){
      console.log(number + "是奇数")
    }else{
      console.log(number + "是偶数")
    }
    // [0-1)
    var score = Math.floor(Math.random()*101);
    if(score >= 90 && score <= 100){
      console.log("A级")
    }else if(score >= 80 && score <90){
      console.log("B级")
    }else if(score >= 70 && score <80){
      console.log("C级")
    }else if(score >= 60 && score <70){
      console.log("D级")
    }else if(score >= 0 && score <60){
      console.log("E级")
    }

    var mouth = Math.floor(Math.random()*12 + 1);
    switch (mouth) {
        case 2:
        case 1:
        case 12:
          console.log("冬季");
          break;
        case 11:
        case 10:
        case 9:
          console.log("秋季");
          break;
        case 8:
        case 7:
        case 6:
          console.log("夏季")
          break;
        default:
          console.log("春季")
    }


  </script>
</body>
</html>